package route

import (
	"codeGenerator/controller"
	"codeGenerator/variable"
)

type CodeAutoRut struct {
	CodeAutoCtl *controller.CodeAutoCtl
}

func NewCodeAutoRut() *CodeAutoRut {
	return &CodeAutoRut{
		CodeAutoCtl: controller.NewCodeAutoCtl(),
	}
}

func (car *CodeAutoRut) CodeAutoRutInit() {
	group := variable.SERVER.NewGroupPath("/codeAuto")
	group.POST("/generator", car.CodeAutoCtl.Generator)
	group.GET("/download", car.CodeAutoCtl.Download)
}
